<template>
  <div>
    <Parent
      :parentDepth="parentDepth - 1"
      :parentdata="parentdata.parent"
      v-if="parentdata.parent"
    />
    <div class="parentComment">
      <div class="info">
        <div class="nickname">
          {{ parentDepth }}
          {{ parentdata.user.nickname }}
          <span class="time">2小时前</span>
        </div>
        <div class="revert">回复</div>
      </div>
      <div class="content">{{ parentdata.content }}</div>
    </div>
  </div>
</template>

<script>
export default {
  name: "Parent",
  props: ["parentdata", "parentDepth"],
  mounted() {},
};
</script>

<style lang="less" scoped>
.parentComment {
  margin: 1px 10px;
  .info {
    font-size: 14px;
    color: #333;
    padding: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  border: 1px solid #ccc;
  .content {
    padding: 10px;
    font-size: 14px;
    color: #333;
  }
  .time {
    color: #666;
    font-size: 10px;
  }
}
</style>
